package com.sky.happygos.network;

import com.sky.happygos.model.Goods;
import com.sky.happygos.model.Login;
import com.sky.happygos.model.RestMessage;
import com.sky.happygos.model.Shop;
import com.sky.happygos.model.Token;

import java.util.List;

import okhttp3.MultipartBody;
import okhttp3.ResponseBody;
import retrofit2.Call;
import retrofit2.http.Body;
import retrofit2.http.Field;
import retrofit2.http.GET;
import retrofit2.http.Multipart;
import retrofit2.http.POST;
import retrofit2.http.Part;
import retrofit2.http.Query;

/**
 * Created by Jin on 2017/4/13.
 */

public interface ApiService {

    @GET("getGoods")
    Call<Goods> getGoods();

    @POST("api/v1/login")
    Call<Token> login(@Body Login login);

    @Multipart
    @POST("api/v1/register")
    Call<RestMessage> register(@Part("phone") long phone, @Part("password") String password,@Part("type") int type);

    @Multipart
    @POST("api/v1/register")
    Call<RestMessage> register(@Part List<MultipartBody.Part> parts);



}
